{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [],
   "source": [
    "import tensorflow as tf\n",
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "import pandas as pd\n",
    "#%matplotlib inline\n",
    "\n",
    "# Generate a random data\n",
    "np.random.seed(0)\n",
    "area = 2.5 * np.random.randn(100) + 25\n",
    "price = 25 * area + 5 + np.random.randint(20,50, size = len(area))\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [],
   "source": [
    "data = np.array([area, price])\n",
    "data = pd.DataFrame(data = data.T, columns=['area','price'])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>area</th>\n",
       "      <th>price</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>29.410131</td>\n",
       "      <td>760.253272</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>26.000393</td>\n",
       "      <td>679.009826</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>27.446845</td>\n",
       "      <td>738.171124</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>30.602233</td>\n",
       "      <td>817.055825</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>29.668895</td>\n",
       "      <td>791.722374</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "        area       price\n",
       "0  29.410131  760.253272\n",
       "1  26.000393  679.009826\n",
       "2  27.446845  738.171124\n",
       "3  30.602233  817.055825\n",
       "4  29.668895  791.722374"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXoAAAD8CAYAAAB5Pm/hAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvnQurowAAHdBJREFUeJzt3X2QXXWd5/H3J50b7OBsOkiGDQ2YrItQImOCvS5WZt0lrDI4q0S0gCln13UocV0f1hTLVuNWjcyWU0Qji/oPW4w4xcyyQgSM7OAaH8I+FDtgdeyEJ8kaR4FcHmyFViENdDrf/eOe27l9+557z+2+j+d+XlVdffvcc7t/J53+9q+/v+/5/hQRmJlZfq3o9gDMzKy9HOjNzHLOgd7MLOcc6M3Mcs6B3sws5xzozcxyzoHezCznHOjNzHLOgd7MLOdWdnsAACeffHJs2LCh28MwM+sr+/bt+2VErGt0Xk8E+g0bNjAxMdHtYZiZ9RVJT2Q5z6kbM7Occ6A3M8s5B3ozs5xzoDczyzkHejOznOuJqhszs0Gxe7LIzj0HeXp6hlNHhrnmorPYtnm0rV/Tgd7MrEN2Txa59u6HmZmdA6A4PcO1dz8M0NZg79SNmVmH7NxzcD7Il83MzrFzz8G2fl0HejOzDnl6eqap463iQG9m1iGnjgw3dbxVHOjNzDrkmovOYrgwtODYcGGIay46q61f14uxZmYdUl5wddWNmVmObds82vbAXs2pGzOznPOM3sysCzp545QDvZlZh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anHYrsK07I8wm7Toi4rsRcTQ57QHgtG6NMas63xOAG4H/QOn/Wk+rcx0fA3ZExCvJc7/o3iizqXMtffUzHyUvJh8WkrcAtgJ3Jsd79ue9V3L0nwZ2SnoK+CJwbZfH0xRJG4DNlH7LnxIRzyRPPQuc0qVhNa3qOir9CfA/Oj2e5ai8FkmXAMWIONDVQS1B1ffkjcA/SVIF/0vSP+rm2JpVdS199zMvaUjSfuAXwPeAnwLTFROiwxyfWPSUXgn0HwO2R8TpwHbgli6PJzNJrwXuAj4dEb+pfC5Kf8/1/AwS0q9D0n8EjgK3dWtszaq8Fkpj/wzwp10d1BLU+J6sBE6ilDK4BtglSV0cYmY1rqXvfuYjYi4iNlH66/ZtwNldHlJmvRLoPwTcnTz+BqV/xJ4nqUDpP+9tEVEe/3OS1ifPr6f027+npVwHkv418C+ADya/tHpejWt5A7AROCDp55R+SH8k6e93b5SNpXxPDgN3J2mEHwLHKPVa6Wkp19KXP/MAETEN3Ae8HRiRVG4lcxpQ7NrA6uiVQP808E+Tx1uBn3RxLJkkM6lbgB9HxH+ueOoeSv+JSd5/q9Nja0badUj6A0o57fdGxJFuja8Zta4lIh6OiN+NiA0RsYFSsDwvIp7t4lDrqvN/azelBVkkvRFYRY83B6tzLX31My9pXbnyTNIw8E5K6w33AR9ITuvZn/eO3zAl6evAP6M0E3kO+CylzpVfpvSn6cvAv42IfR0dWJMk/T7wf4CHKc2soJQieJDSSvwZlCo8LouI6sXnnlHnOr4CnAD8Kjn2QET8m86PMLu0a4mIb1ec83NgLCJ6NkDW+Z58H/gasAl4Ffj3EbG3K4PMqM61/IY++pmX9HuUFluHKE2Qd0XEf5L0D4DbKaXUJoE/Li+W9xLfGWtmlnO9kroxM7M2caA3M8s5B3ozs5xzoDczyzkHejOznHOgNzPLOQd6M7Occ6A3M8u5/w8YcJoLjULWcAAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(data['area'], data['price'])\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [],
   "source": [
    "W = sum(price*(area-np.mean(area))) / sum((area-np.mean(area))**2)\n",
    "b = np.mean(price) - W*np.mean(area)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The regression coefficients are 24.815544052284988 43.4989785533412\n"
     ]
    }
   ],
   "source": [
    "print(\"The regression coefficients are\", W,b)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [],
   "source": [
    "# predicted values\n",
    "y_pred = W * area + b"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEKCAYAAAAIO8L1AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDMuMC4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvnQurowAAIABJREFUeJzt3Xt8lOWZ//HPRQgSFAkqnoIKIqKgEDAeKKittCpqFa1WXbse6q/oau3Wtgjs2pW29gUu1kO3XSxbrVbxfEhRW0HF1pYWNQjIWbCiJKIiAiogJOH6/THPhDk8M5nETOaQ7/v1yisz9zzPk/shZK65T9dt7o6IiEiiTrmugIiI5CcFCBERCaUAISIioRQgREQklAKEiIiEUoAQEZFQChAiIhJKAUJEREIpQIiISKjOua7AF7HPPvt4nz59cl0NEZGCMn/+/I/cvVdzxxV0gOjTpw81NTW5roaISEExs3cyOU5dTCIiEkoBQkREQilAiIhIqIIegwhTX19PbW0tn3/+ea6rIi3QtWtXevfuTWlpaa6rIiKBogsQtbW1dO/enT59+mBmua6OZMDd2bBhA7W1tfTt2zfX1RGRQNF1MX3++efsvffeCg4FxMzYe++91eoTyTNFFyAABYcCpN+ZSP4pygAhIiJfnAJEFpSUlFBZWclRRx3FBRdcwNatW1t9rT//+c+cddZZAMycOZMpU6akPHbTpk387//+b4t/xqRJk7j11ltDyysqKpruZebMmaHnN1cvEWmd6gV1jJgyh74TnmXElDlUL6hr15+vAJEFZWVlLFy4kCVLltClSxfuuuuuuNfdnZ07d7b4umeffTYTJkxI+XprA0Q6119/PQsXLuSxxx7j29/+dlK9Gxoamq2XiLRc9YI6Jj65mLpN23CgbtM2Jj65uF2DhAJElp144omsXr2aNWvWMGDAAC699FKOOuoo1q5dy+zZsxk+fDjDhg3jggsu4LPPPgPgueee44gjjmDYsGE8+eSTTde69957+e53vwvABx98wLnnnsuQIUMYMmQIf//735kwYQJvvfUWlZWVjBs3DoCpU6dy7LHHMnjwYG666aama/385z/n8MMPZ+TIkaxcubLZ+zjyyCPp3LkzH330EZdffjlXX301xx9/PDfccEOz9QJ44IEHOO6446isrOSqq66isbGxbf6BRYrU1Fkr2VYf/3eyrb6RqbOa/3ttK0U3zTXO978PCxe27TUrK+GOOzI6tKGhgT/96U+cfvrpAKxatYr77ruPE044gY8++oibb76ZF154gd13351bbrmF2267jRtuuIHvfOc7zJkzh8MOO4wLL7ww9Nrf+973OPnkk3nqqadobGzks88+Y8qUKSxZsoSFwT3Pnj2bVatW8eqrr+LunH322bz88svsvvvuPPzwwyxcuJCGhgaGDRvGMccck/ZeXnnlFTp16kSvXpH8XrW1tfz973+npKSEe++9N229li9fziOPPMLcuXMpLS3lmmuuYcaMGVx66aUZ/TuKdETvbdrWovJsKO4AkSPbtm2jsrISiLQgrrzySt577z0OOeQQTjjhBADmzZvHsmXLGDFiBAA7duxg+PDhrFixgr59+9K/f38AvvWtbzF9+vSknzFnzhx+//vfA5Exjx49erBx48a4Y2bPns3s2bMZOnQoAJ999hmrVq3i008/5dxzz6Vbt25ApOsqldtvv50HHniA7t2788gjjzTNN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
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.plot(area, y_pred, color='red',label=\"Predicted Price\")\n",
    "plt.scatter(data['area'], data['price'], label=\"Training Data\")\n",
    "plt.xlabel(\"Area\")\n",
    "plt.ylabel(\"Price\")\n",
    "plt.legend()\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python [conda env:tf2p0alpha]",
   "language": "python",
   "name": "conda-env-tf2p0alpha-py"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.8"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
